package com.yyx.demo1.service;

import com.yyx.demo1.entity.User;
import com.yyx.demo1.repository.UserRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class UserServiceImpl implements UserService{
    @Autowired
    UserRepository userRepository;
    @Override
    public User login(User user) {
        return userRepository.login(user);
    }

    @Override
    public int register(User user) {
        return userRepository.register(user);
    }
}
